/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package interpreter;

/**
 *
 * @author Elise
 */
public class Divisao extends AbstractExpression {

    private AbstractExpression esq;
    private AbstractExpression dir;

    /**
     * @return the esq
     */
    Divisao(AbstractExpression esq, AbstractExpression dir) {
        this.esq = esq;
        this.dir = dir;
    }

    @Override
    public float getResultado() {
        return esq.getResultado() / dir.getResultado();
    }

    public AbstractExpression getEsq() {
        return esq;
    }

    /**
     * @param esq the esq to set
     */
    public void setEsq(AbstractExpression esq) {
        this.esq = esq;
    }

    /**
     * @return the dir
     */
    public AbstractExpression getDir() {
        return dir;
    }

    /**
     * @param dir the dir to set
     */
    public void setDir(AbstractExpression dir) {
        this.dir = dir;
    }
}
